package com.example.shoppingmall.service;

import com.example.shoppingmall.dao.AdvertisingMapper;
import com.example.shoppingmall.pojo.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional
public class AdvertisService{
    @Autowired
    AdvertisingMapper advertisingMapper;

    public List<Advertising> getAdvertisingAll(String Advertisementname, String utime, Integer pageno, Integer pageSize) {
        return advertisingMapper.getAdvertisingAll(Advertisementname, utime, pageno, pageSize);
    }

    public int advertisingcount(String Advertisementname, String utime) {
        return advertisingMapper.advertisingcount(Advertisementname,utime);
    }

    public int addAdvertising(Advertising advertising) {
        return advertisingMapper.addAdvertising(advertising);
    }

    public int updAdvertising(Advertising advertising) {
        return advertisingMapper.updAdvertising(advertising);
    }

    public Advertising selAdvertising(Integer id) {
        return advertisingMapper.selAdvertising(id);
    }

    public int delAdvertising(Integer id) {
        return advertisingMapper.delAdvertising(id);
    }

    public List<Advertisingtype> getAdvertisingtype() {
        return advertisingMapper.getAdvertisingtype();
    }

    public List<Advertisingspace> getAdvertisingspace() {
        return advertisingMapper.getAdvertisingspace();
    }

    public List<Commodity> getCommoditylist() {
        return advertisingMapper.getCommoditylist();
    }

    public List<Articlelist> getArticlelistall() {
        return advertisingMapper.getArticlelistall();
    }

    public List<Article> getArticletypes() {
        return advertisingMapper.getArticletypes();
    }
}
